Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add tests for service callbacks #594

Merged
merged 4 commits into from
Nov 30, 2023
Merged

Conversation

techfg
Copy link
Contributor

@techfg techfg commented Nov 10, 2023

I noticed that the testConfig state is mutated within some tests which results in subsequent tests having the mutated config making the tests order dependent and potential side-effects across tests. I implemented a basic approach to ensure each test starts with a fresh config (alternative approach would be a factory/deepClone of the config). If you'd like me to revert this part, just let me know.

Thank you!

Copy link

vercel bot commented Nov 10, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
cookieconsent-docs ⬜️ Ignored (Inspect) Visit Preview Nov 30, 2023 8:18pm

@techfg techfg changed the title fix service callbacks - resolves #593 add tests for service callbacks Nov 13, 2023
@techfg
Copy link
Contributor Author

techfg commented Nov 13, 2023

Per discussion in #593, reverted behavior on calling onAccept/onReject and updated tests to match expected behavior.

Copy link
Owner

@orestbida orestbida left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution!

@orestbida orestbida merged commit d502966 into orestbida:v3 Nov 30, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: v3 - Service callbacks onAccept & onReject are not called unless both are defined
2 participants